In the past, debugging digital signal processors was done using a scan control unit that converts parallel information from a test and debug processing unit into a serial data stream. The number of bits to be scanned out for each operation is loaded into a scan length register before each scan. If a digital signal processor has several scan paths with different lengths, which must be scanned in order to perform an operation, then the scan length register must be loaded before each scan.
In a high performance scan control unit, the number of times the test and debug unit must load the registers in the scan controller can become a limiting factor of the performance of the testing procedure. This problem is compounded by the increasing speed of the test clock, which is the speed at which data is serialized and sent to the target processor.
There are two efficiency factors that govern the performance of a test and debug system. These factors are the inherent efficiency of the target processor itself, and the efficiency of the scan controller. The efficiency of the target processor relates to how many bits of information and control signals must be sent to the target processor to perform an operation such as a single step operation, memory access operation, or register access operation. This factor is ignored by this invention since the digital signal processor efficiency cannot be altered by the scan controller implementation.
The efficiency of the scan control unit relates to how many bits must be loaded into the scan control unit to cause it to send out the required number of bits for the digital signal processor to perform an operation with no dead time between operations.
If we assume a scan control unit has a 16-bit interface with the test and debug unit, and the test clock rate is 32 MHz, the scan control unit must be provided with a data value every 500 ns in order to run at 100% efficiency. In addition, the test and debug unit must load control information into the scan control unit to control the scans and the target processor JTAG interface, as well as access status from the scan control unit related to the scan operations. If the scan control unit access time and test and debug unit memory access times are on the order of 100 ns, then 40% of the bus bandwidth is consumed just by data transfers to the target signal processor. If the target processor is also returning information, then data transfers will be consuming 80% of the bus bandwidth. If the test and debug unit must access the scan control unit to determine if a data value can be loaded or read, the remaining 20% of the bus bandwidth is used up, leaving no time for loading control information into the scan controller, or execution of instructions by the debug unit.
These issues can be addressed in 3 ways: widen the data path between the test and debug unit and the scan control unit and memory, reduce the access time, and reduce the number of times the scan control unit must be accessed. Widening the data path requires additional pins on the scan control unit device, the debug unit and the memory, and may not always be possible. Reducing the access time of the scan control unit or memory might be possible, but is limited by the particular implementation of both. Reducing the number of accesses of the scan control unit provides a means of improving the efficiency, which can be applied in conjunction with the other two techniques.
Referring to FIG. 1, a block diagram of a test and debug system capable of advantageously using the present invention is shown. The test and debug system includes a user interface 5, a test and debug unit 10, and a target processor 15. The user interface 5 includes the apparatus that permits a user to interact with, and control the testing of, the target processing unit 15. The user interface 5 can include display apparatus, input apparatus such as a keyboard, etc. for initiating test and debug procedures and for receiving the results of these procedures. The user interface 5 is coupled to the test and debug unit 10 through interface unit 101. The interface unit 101 exchanges signals with the processing unit 102 of the test and debug unit 10. The processing unit 102 applies signals to and receives signals from the scan control unit 103. The scan control unit 103 includes a local processor 1031, and memory unit out 1032 for exchanging signals with the local processor 1031, a memory unit in 1035 for storing signals from the target processing unit 15, a shift register out 1034 and a shift register in 1033, the shift registers 1033 and 1034 transferring data in and out of the test and debug unit 10 under control of the local processor 1031. For purposes of the present invention, the processing unit 102 provides commands to the scan control unit 103 and supplies the contents of the memory unit 1032. The target processing unit 15 includes a test access port 151, a shift register 152, an instruction register 153, a data register 154, a mini-state register 155 and a data register 156. The test access port 151 is a state machine responsive to test mode select (TMS) signals from the processing unit 102 for controlling the JTAG apparatus in the target processing unit 15. The shift register 152 receives signals from the shift register out 1034 and transfers signals to the shift register in 1033. The shift register 152 applies signals to the instruction register 153 and with the data register 154 and receives signals from the mini-status register 155 and the data register 156.
Referring to FIG. 2, a portion of the contents of the memory unit out 1032, according to the prior art, is illustrated. In particular, the memory unit out 1032 includes a command parameter section 1032A. Examples of the parameters included in the command parameter section are parameters defining the number of bits to transfer, the type of scan, the data to scan, and parameters defining JTAG end states. A command from the processing unit 102 will include reference to these parameters and these parameters will be accessed and appropriate control signals applied to the test access port 151 by the local processor.
Referring to FIG. 3, the execution of a command is illustrated. Before a command can be issued, all the parameters, including scan length, must be loaded into the scan controller. When command A is issued, the command active signal is activated. The command active signal allows the go to shift state function, the send/receive function, and the go to end state to be executed by the scan control unit 103. When the command active signal is no longer active, then the parameter for command B can be loaded and a next command B can be executed.
A need has been felt for apparatus and an associated method having the feature of being able to increase the rate of transfer of information from a test and debug unit to a target processor in JTAG test procedures. It would be yet another feature of the apparatus and associated method to reduce the number of accesses of the test and debug unit with the scan control unit. It would be a more particular object of the present invention to provide a plurality of scan length registers, each register having a different bit length. It would be another particular feature of the apparatus and associated method to provide a field in a command from the test and debug unit to the scan control unit that identifies the scan length register having the signal group to be transferred to the test processing unit. It would be get another feature of the apparatus and associated method to transfer the signal group in the scan length register identified by the command to the target processor without further communication from the test and debug unit.